<template>
  <div class="app-container" ref="content">
    <div style="text-align: center;padding: 10px">维保记录《{{recordsInfo.remark}}》-详情信息</div>
    <div style="width: 50%;margin:0px auto;vertical-align:middle;height:100%">
      <el-form :model="recordsInfo" ref="recordsInfo" label-width="150px">
        <el-form-item label="维保人员:" prop="userName">
          {{ recordsInfo.userName }}
        </el-form-item>
        <el-form-item label="业主名称:" prop="enterpriseName">
          {{ recordsInfo.enterpriseName }}
        </el-form-item>
        <el-form-item label="设备名称:" prop="equipmentName">
          {{ recordsInfo.equipmentName }}
        </el-form-item>
        <el-form-item label="维保企业:" prop="maintenaceEnterpriseName">
          {{ recordsInfo.maintenaceEnterpriseName}}
        </el-form-item>
        <el-form-item label="维保详情:" prop="remark">
          {{ recordsInfo.remark}}
        </el-form-item>
      </el-form>
    </div>
  </div>
</template>

<script>
import {getInRecordsVo} from "../../../api/maintenanceRecord";

export default {
  name: "recordsInfo",
  data(){
    return{

      recordsInfo:{
      },

    }
  },
  created() {
    this.$nextTick(() => {
      this.getInRecordsVo(this.$route.query.ucId)

    });
  },
  methods:{
    getInRecordsVo(val){
      let loadingInstance = this.$loading({
        target:this.$refs.content,
        text:'数据加载中'
      });
      getInRecordsVo({ucId:val}).then(res=>{
        console.log(res)
        this.recordsInfo = res.data
        loadingInstance.close()
        this.$notify.success({
          title: '成功',
          message: "获取维保记录成功"
        })

      }).catch(error=>{
        console.log(error)
        loadingInstance.close()
        this.$notify.error({
          title: '失败',
          message: "获取维保记录信息失败"
        })
      })
    },


  }

}
</script>

<style>

</style>